package hr.fer.zemris.math;

import hr.fer.zemris.gep.INode;
import hr.fer.zemris.gep.ANode;
import hr.fer.zemris.gep.NodeEvaluation;

public class ConstTerminal extends ANode implements INode {
	Double value;
	
	public ConstTerminal(double v) {
		value = v;
	}
	
	@Override
	public int getAirity() {
		return 0;
	}

	@Override
	public Object evaluate(Object args[]) {
		return value;
	}
	

	@Override
	public String print(NodeEvaluation[] nodeEvals) {
		return value.toString();
	}
}
